package com.project.internship.service;

import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.project.internship.entity.Allot;
import com.baomidou.mybatisplus.extension.service.IService;
import com.project.internship.entity.Student;
import com.project.internship.entity.Teacher;
import com.project.internship.vo.StudentDeptMajorClassVO;
import com.project.internship.vo.StudentRecordVO;
import com.project.internship.vo.TeacherDeptVO;
import org.springframework.transaction.annotation.Transactional;

import java.util.List;

/**
 * <p>
 *  服务类
 * </p>
 *
 * @author author
 * @since 2020-04-11
 */
public interface AllotService extends IService<Allot> {

    /**
     * 教师端查询学生信息
     * @param page
     * @param keyword 学号
     * @return
     */
    IPage<StudentDeptMajorClassVO> getAllAllotStudents(Page<StudentDeptMajorClassVO> page, String keyword);

    /**
     * 学院端查询学生信息
     * @param page
     * @param keyword 学号
     * @return
     */
    IPage<StudentDeptMajorClassVO> getAllReceivedStudents(Page<StudentDeptMajorClassVO> page, String keyword);

    int addAllot(Integer bid, Integer[] tids, Integer[] sids);

    Integer updateAllot(Integer bid, Integer[] tids, Integer[] sids);

    Integer deleteAllot(Integer bid);

    IPage<StudentDeptMajorClassVO> getBaseStudent(Page<StudentDeptMajorClassVO> page, Integer bid);

    IPage<StudentRecordVO> getStudentRecord(Page<StudentRecordVO> page, String keyword);
}
